<?php

use Illuminate\Database\Seeder;

class PersonTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        factory(App\Person::class, 10)->create()->each(
            function ($person) {
                $person->posts()->save(factory(App\Post::class)->make());
            }
        );
    }
}
